Class LabelPropagation
java.lang.Object
edu.claflin.finder.algo.Algorithm
edu.claflin.finder.algo.clustering.ClusteringAlgorithm
edu.claflin.finder.algo.clustering.LabelPropagation
- All Implemented Interfaces:
Processable<Graph,Graph>
TODO: MAKE COMMENTS NICE
abc
- Author:
- Adam
-
Nested Class Summary
Nested classes/interfaces inherited from class edu.claflin.finder.algo.Algorithm
Algorithm.GraphSortOrder -
Field Summary
Fields inherited from class edu.claflin.finder.algo.Algorithm
args, PROP_PROGRESS -
Constructor Summary
ConstructorsConstructorDescriptionLabel Propagation Algorithm (LPA) for Community Detection. -
Method Summary
Modifier and TypeMethodDescriptiongenerateCommunityFromLabel(int target, int[] labels, Graph graph) Performs FastGreedy community detection on a given Graph, returning the clustering with the maximum modularity.generateRandomOrder(List<Node> allNodes) Makes a random order for LPA algorithm.Performs Label Propagation (LPA) community detection on a given Graph, returning the significant communities present within a network.toString()Methods inherited from class edu.claflin.finder.algo.clustering.ClusteringAlgorithm
buildCommunityGraphs, isWeightedMethods inherited from class edu.claflin.finder.algo.Algorithm
addPropertyChangeListener, cull, getGraphSortOrder, getMinNodeCount, getPartiteNumber, getWeightName, removePropertyChangeListener, setGraphSortOrder, setMinNodeCount, setPartiteNumber, setProgress, setWeightName, zeropad
-
Constructor Details
-
LabelPropagation
Label Propagation Algorithm (LPA) for Community Detection. Based on python's igraph library.- Parameters:
args- args- See Also:
-
-
Method Details
-
toString
-
generateRandomOrder
Makes a random order for LPA algorithm.- Parameters:
allNodes- is the list of nodes- Returns:
- The a random order for node changing in the next iteration.
-
generateCommunityFromLabel
Performs FastGreedy community detection on a given Graph, returning the clustering with the maximum modularity.- Parameters:
target- the Graph to perform FastGreedy onlabels- the Graph to perform FastGreedy ongraph- the Graph to perform function on- Returns:
- the list of Graphs representing the clustering with the maximum modularity
-
process
Performs Label Propagation (LPA) community detection on a given Graph, returning the significant communities present within a network.- Parameters:
graph- the Graph to perform LPA on- Returns:
- the list of Graphs representing the significant partitioned clusters.
-